/**
 * @(#)DrawView.java   2012-10-4
 * 
 * CopyRight (c) 2012-2020 TCL Digital Technology (shenzhen) CO.,Ltd. All rights reserved.
 * 
 * @description: 
 * 
 * @version: 1.0
 * 
 * @modification history:
 *     2012-10-4 Modified By zhaodm : Create
 * 
 * 
 */
package org.crazyit.helloworld;

import android.content.Context;
import android.graphics.Canvas;
import android.graphics.Color;
import android.graphics.Paint;
import android.util.AttributeSet;
import android.view.View;

/**
 * @description: 
 * 
 */
public class DrawView extends View {
	
	public float currentX = 40;
	public float currentY = 50;

	/**
	 * 
	 * @param context 
	 */
	public DrawView(Context context) {
		super(context);
		// TODO Auto-generated constructor stub
	}

	/**
	 * 
	 * @param context
	 * @param attrs 
	 */
	public DrawView(Context context, AttributeSet attrs) {
		super(context, attrs);
		// TODO Auto-generated constructor stub
	}

	/**
	 * 
	 * @param context
	 * @param attrs
	 * @param defStyle 
	 */
	public DrawView(Context context, AttributeSet attrs, int defStyle) {
		super(context, attrs, defStyle);
		// TODO Auto-generated constructor stub
	}
	
	public void onDraw(Canvas canvas) {
		super.onDraw(canvas);
		Paint p = new Paint();
		p.setColor(Color.RED);
		
		canvas.drawCircle(currentX, currentY, 15, p);
	}

}
